package com.lanou.wuyou.gift.home;

import android.content.Intent;
import android.os.Build;
import android.os.Bundle;
import android.support.annotation.Nullable;
import android.support.v7.app.AppCompatActivity;
import android.webkit.WebSettings;
import android.webkit.WebView;

import com.lanou.wuyou.gift.R;

/**
 * Created by dllo on 17/3/25.
 */

public class HomeListItemWebOne extends AppCompatActivity{
    @Override
    protected void onCreate(@Nullable Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_home_list_web_one);
        WebView webView = (WebView) findViewById(R.id.home_list_web_one);
        Intent intent = getIntent();
        int id = intent.getIntExtra("id",0);
        if (Build.VERSION.SDK_INT > Build.VERSION_CODES.KITKAT) {
            webView.getSettings().setMixedContentMode(WebSettings.MIXED_CONTENT_ALWAYS_ALLOW);
        }
        webView.getSettings().setBlockNetworkImage(false);
        webView.loadUrl("https://hawaii.liwushuo.com/posts/" + id);
    }
}
